package com.huiyou.service.mapper;

import com.huiyou.item.pojo.WpOrderPf;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface WpOrderPfMapper extends Mapper<WpOrderPf> {

    @Select("SELECT * FROM `wp_order_pf` WHERE `date` <= #{s} AND `date` >= #{s1} ORDER BY `isok` DESC LIMIT 0, 1000")
    List<WpOrderPf> findByDate(@Param("s") String s, @Param("s1") String s1);

    @Select("SELECT * FROM `wp_order_pf` WHERE" +
            " `status` = 1 AND FROM_UNIXTIME(ptime) >= #{startData} and FROM_UNIXTIME(ptime) < #{endData}")
    List<WpOrderPf> findOrderPfByData(@Param("startData")String startData, @Param("endData")String endData);
}
